var x = {};

x.calculatePrice = function(app, that)
{
    var theData = that.data;
    var summaryPrice = x.formatPrice(theData.product.dry_price - theData.codePrice);
    var data = {
        summaryPrice: summaryPrice
    };
    that.setData(data);
};

x.formatPrice = function(i)
{
    return i.toFixed(2);
};

module.exports = x;